package com.example.servicebase.client;

import com.example.commonutils.ordervo.MemberForOrder;
import feign.hystrix.FallbackFactory;
import org.springframework.stereotype.Component;

import java.util.Map;

@Component
public class UcenterClientFallbackFactory implements FallbackFactory<UcenterClient> {
    @Override
    public UcenterClient create(Throwable throwable) {
        return new UcenterClient() {
            @Override
            public MemberForOrder getUserForOrder(String userId) {
                return null;
            }

            @Override
            public Map<String, String> getUserInfo(String memberId) {
                return null;
            }

            @Override
            public Integer countRegister(String date) {
                return 0;
            }

            @Override
            public Integer LoginCount() {
                return 0;
            }
        };
    }

}
